﻿namespace ACCOUNTING
{
    using ACCOUNTING.LVY.Business;
    using ACCOUNTING.My.Resources;
    using Microsoft.VisualBasic;
    using Microsoft.VisualBasic.CompilerServices;
    using System;
    using System.Collections.Generic;
    using System.ComponentModel;
    using System.Diagnostics;
    using System.Drawing;
    using System.Runtime.CompilerServices;
    using System.Windows.Forms;

    [DesignerGenerated]
    public class Frm_CapNhatGiaVonXuatKho : Form
    {
        private static List<WeakReference> __ENCList = new List<WeakReference>();
        [AccessedThroughProperty("CboDonVi")]
        private ComboBox _CboDonVi;
        [AccessedThroughProperty("CmdCancel")]
        private Button _CmdCancel;
        [AccessedThroughProperty("CmdOK")]
        private Button _CmdOK;
        [AccessedThroughProperty("GroupBox1")]
        private GroupBox _GroupBox1;
        [AccessedThroughProperty("Label1")]
        private Label _Label1;
        [AccessedThroughProperty("Label2")]
        private Label _Label2;
        [AccessedThroughProperty("Label3")]
        private Label _Label3;
        [AccessedThroughProperty("updNam")]
        private NumericUpDown _updNam;
        [AccessedThroughProperty("updThang")]
        private NumericUpDown _updThang;
        private IContainer components;
        private bool mAllowAdd;
        private bool mAllowDel;
        private bool mAllowEdit;
        private bool mAllowView;
        private clsXuatKho objXK;

        public Frm_CapNhatGiaVonXuatKho()
        {
            base.Load += new EventHandler(this.Frm_CapNhatGiaVonXuatKho_Load);
            List<WeakReference> list = __ENCList;
            lock (list)
            {
                __ENCList.Add(new WeakReference(this));
            }
            this.objXK = new clsXuatKho();
            this.InitializeComponent();
        }

        private void CmdCancel_Click(object sender, EventArgs e)
        {
            this.Dispose();
        }

        private void CmdOK_Click(object sender, EventArgs e)
        {
            this.Cursor = Cursors.WaitCursor;
            string strNamThang = Conversions.ToString(this.updNam.Value) + LVYModule.sRight("00" + Conversions.ToString(this.updThang.Value), 2);
            if (!this.objXK.CapNhatGiaVon(Conversions.ToString(this.CboDonVi.SelectedValue), strNamThang))
            {
                this.Cursor = Cursors.Default;
            }
            else
            {
                this.Cursor = Cursors.Default;
                LVYModule.ShowWarning(modGeneral.Tranlated("Nghiệp vụ cập nhật gi\x00e1 vốn ho\x00e0n tất!", ""));
            }
        }

        [DebuggerNonUserCode]
        protected override void Dispose(bool disposing)
        {
            if (disposing && (this.components != null))
            {
                this.components.Dispose();
            }
            base.Dispose(disposing);
        }

        private void Frm_CapNhatGiaVonXuatKho_Load(object sender, EventArgs e)
        {
            this.Cursor = Cursors.WaitCursor;
            LVYModule.GetUserRight(ref this.mAllowView, ref this.mAllowDel, ref this.mAllowEdit, ref this.mAllowAdd, Conversions.ToString(this.Tag), modGeneral.H_USERNAME);
            if (!this.mAllowView)
            {
                LVYModule.ShowWarning(modGeneral.Tranlated("Bạn kh\x00f4ng c\x00f3 quyền xem, li\x00ean hệ với người quản trị để biết th\x00eam chi tiết.", ""));
                this.Dispose();
            }
            else
            {
                BuildComboModule.BuildCombo(this.CboDonVi, modGeneral.ListDanhMuc.DonVi, false, "", "");
                this.CboDonVi.SelectedValue = modGeneral.H_CLIENT;
                this.updThang.Value = new decimal(DateAndTime.Month(DateAndTime.Today));
                this.updNam.Value = new decimal(DateAndTime.Year(DateAndTime.Today));
                this.Cursor = Cursors.Default;
            }
        }

        [DebuggerStepThrough]
        private void InitializeComponent()
        {
            ComponentResourceManager manager = new ComponentResourceManager(typeof(Frm_CapNhatGiaVonXuatKho));
            this.CmdCancel = new Button();
            this.Label2 = new Label();
            this.CmdOK = new Button();
            this.updNam = new NumericUpDown();
            this.Label1 = new Label();
            this.GroupBox1 = new GroupBox();
            this.Label3 = new Label();
            this.CboDonVi = new ComboBox();
            this.updThang = new NumericUpDown();
            this.updNam.BeginInit();
            this.GroupBox1.SuspendLayout();
            this.updThang.BeginInit();
            this.SuspendLayout();
            this.CmdCancel.DialogResult = DialogResult.Cancel;
            this.CmdCancel.Image = (Image) manager.GetObject("CmdCancel.Image");
            this.CmdCancel.ImageAlign = ContentAlignment.MiddleLeft;
            Point point = new Point(0x10f, 0x88);
            this.CmdCancel.Location = point;
            this.CmdCancel.Name = "CmdCancel";
            Size size = new Size(0x4f, 0x18);
            this.CmdCancel.Size = size;
            this.CmdCancel.TabIndex = 12;
            this.CmdCancel.Text = "&Tho\x00e1t";
            this.CmdCancel.UseVisualStyleBackColor = true;
            this.Label2.AutoSize = true;
            point = new Point(0x95, 0x4a);
            this.Label2.Location = point;
            this.Label2.Name = "Label2";
            size = new Size(0x1d, 13);
            this.Label2.Size = size;
            this.Label2.TabIndex = 11;
            this.Label2.Text = "Năm";
            this.CmdOK.Image = (Image) manager.GetObject("CmdOK.Image");
            this.CmdOK.ImageAlign = ContentAlignment.MiddleLeft;
            point = new Point(0xbc, 0x88);
            this.CmdOK.Location = point;
            this.CmdOK.Name = "CmdOK";
            size = new Size(0x4e, 0x18);
            this.CmdOK.Size = size;
            this.CmdOK.TabIndex = 11;
            this.CmdOK.Text = "&Chọn";
            this.CmdOK.UseVisualStyleBackColor = true;
            point = new Point(0xc2, 0x48);
            this.updNam.Location = point;
            decimal num = new decimal(new int[] { 0x9c4, 0, 0, 0 });
            this.updNam.Maximum = num;
            num = new decimal(new int[] { 0x7d0, 0, 0, 0 });
            this.updNam.Minimum = num;
            this.updNam.Name = "updNam";
            size = new Size(0x3a, 20);
            this.updNam.Size = size;
            this.updNam.TabIndex = 10;
            num = new decimal(new int[] { 0x7d0, 0, 0, 0 });
            this.updNam.Value = num;
            this.Label1.AutoSize = true;
            point = new Point(0x17, 0x4c);
            this.Label1.Location = point;
            this.Label1.Name = "Label1";
            size = new Size(0x26, 13);
            this.Label1.Size = size;
            this.Label1.TabIndex = 9;
            this.Label1.Text = "Th\x00e1ng";
            this.GroupBox1.BackColor = Color.Transparent;
            this.GroupBox1.Controls.Add(this.Label3);
            this.GroupBox1.Controls.Add(this.CboDonVi);
            this.GroupBox1.Controls.Add(this.Label2);
            this.GroupBox1.Controls.Add(this.updNam);
            this.GroupBox1.Controls.Add(this.Label1);
            this.GroupBox1.Controls.Add(this.updThang);
            point = new Point(6, 3);
            this.GroupBox1.Location = point;
            this.GroupBox1.Name = "GroupBox1";
            size = new Size(0x158, 0x7a);
            this.GroupBox1.Size = size;
            this.GroupBox1.TabIndex = 13;
            this.GroupBox1.TabStop = false;
            this.GroupBox1.Text = "T\x00f9y chọn";
            this.Label3.AutoSize = true;
            point = new Point(0x17, 40);
            this.Label3.Location = point;
            this.Label3.Name = "Label3";
            size = new Size(0x26, 13);
            this.Label3.Size = size;
            this.Label3.TabIndex = 13;
            this.Label3.Text = "Đơn vị";
            this.CboDonVi.FormattingEnabled = true;
            point = new Point(0x56, 0x25);
            this.CboDonVi.Location = point;
            this.CboDonVi.Name = "CboDonVi";
            size = new Size(0xfc, 0x15);
            this.CboDonVi.Size = size;
            this.CboDonVi.TabIndex = 12;
            point = new Point(0x56, 0x49);
            this.updThang.Location = point;
            num = new decimal(new int[] { 12, 0, 0, 0 });
            this.updThang.Maximum = num;
            num = new decimal(new int[] { 1, 0, 0, 0 });
            this.updThang.Minimum = num;
            this.updThang.Name = "updThang";
            size = new Size(0x2d, 20);
            this.updThang.Size = size;
            this.updThang.TabIndex = 8;
            num = new decimal(new int[] { 1, 0, 0, 0 });
            this.updThang.Value = num;
            SizeF ef = new SizeF(6f, 13f);
            this.AutoScaleDimensions = ef;
            this.AutoScaleMode = AutoScaleMode.Font;
            this.BackgroundImage = ACCOUNTING.My.Resources.Resources.background;
            size = new Size(0x167, 0xa5);
            this.ClientSize = size;
            this.ControlBox = false;
            this.Controls.Add(this.CmdCancel);
            this.Controls.Add(this.CmdOK);
            this.Controls.Add(this.GroupBox1);
            this.FormBorderStyle = FormBorderStyle.FixedDialog;
            this.MaximizeBox = false;
            this.MinimizeBox = false;
            this.Name = "Frm_CapNhatGiaVonXuatKho";
            this.StartPosition = FormStartPosition.CenterScreen;
            this.Tag = "ST-0003";
            this.Text = "CAP NHAT GIA VON XUAT KHO";
            this.updNam.EndInit();
            this.GroupBox1.ResumeLayout(false);
            this.GroupBox1.PerformLayout();
            this.updThang.EndInit();
            this.ResumeLayout(false);
        }

        internal virtual ComboBox CboDonVi
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CboDonVi;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._CboDonVi = value;
            }
        }

        internal virtual Button CmdCancel
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CmdCancel;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.CmdCancel_Click);
                if (this._CmdCancel != null)
                {
                    this._CmdCancel.Click -= handler;
                }
                this._CmdCancel = value;
                if (this._CmdCancel != null)
                {
                    this._CmdCancel.Click += handler;
                }
            }
        }

        internal virtual Button CmdOK
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CmdOK;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.CmdOK_Click);
                if (this._CmdOK != null)
                {
                    this._CmdOK.Click -= handler;
                }
                this._CmdOK = value;
                if (this._CmdOK != null)
                {
                    this._CmdOK.Click += handler;
                }
            }
        }

        internal virtual GroupBox GroupBox1
        {
            [DebuggerNonUserCode]
            get
            {
                return this._GroupBox1;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._GroupBox1 = value;
            }
        }

        internal virtual Label Label1
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label1;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label1 = value;
            }
        }

        internal virtual Label Label2
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label2;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label2 = value;
            }
        }

        internal virtual Label Label3
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label3;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label3 = value;
            }
        }

        internal virtual NumericUpDown updNam
        {
            [DebuggerNonUserCode]
            get
            {
                return this._updNam;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._updNam = value;
            }
        }

        internal virtual NumericUpDown updThang
        {
            [DebuggerNonUserCode]
            get
            {
                return this._updThang;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._updThang = value;
            }
        }
    }
}

